const state = {
  loading: false
}

const mutations = {
  showloading (state) {
    state.loading = true
  },
  hideloading (state) {
    state.loading = false
  }
}

const actions = {
  closeloading (context) {
    context.commit('hideloading')
  },
  openloading (context) {
    context.commit('showloading')
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}
